{% extends "profilebase.html" %}
{% load myprofile_extras %}
{% block sidebar2 %}
</br>
{% if profileOwner %}
	{% if currentUser.category == "institute" %}
		<div style="font-size:20;"><b>About Us</b></div></br>
	{% else %}
		<div style="font-size:20;"><b>About Me</b></div></br>
	{% endif %}
	{% if photo %}			
		<img border="0" src={{ photo.path }} />
	{% endif %}
	<br/>
	
	<small>
		<br/>
		<a href="/editInfo/">Edit My Info</a> - 
		{% if photo %}	
			<a href="/myprofile/uploadImage/">Change Photo</a> - 
		{% else %}
			<a href="/myprofile/uploadImage/">Upload a Photo</a> - 
		{% endif %}
		<a href="/myprofile/changePassword/">Change Password</a>
		<br/>
	</small>
{% else %}
	<div style="font-size:20;"><b>About {{ currentUser.abstract_user.user.username }}</b></div></br>
	{% if photo %}			
		<img border="0" src={{ photo.path }} />
	{% endif %}
{% endif %}
<br/>


{% if currentUser.category == "teacher" %}
	{% if my_institutes %}
			<b>Works at:</b>
			{% for institute in my_institutes|limit_array:4 %}
				</br><a href="/myprofile/{{ institute.abstract_user.id }}/">{{ institute.abstract_user }}</a><br/>
			{% endfor %}
			{% if my_institutes|length > 4 %}
				<small><a href="/myprofile/connections/{{ currentUser.abstract_user.id }}/">See all</a></small>
			{% endif %}
			</br><br/>
	{% endif %}
{% endif %}


{% if profileOwner %}
	{% if currentUser.category == "institute" %}
	<br/>
		<b>About: </b><br/>{{ currentUser.about|default:"Tell us all about your institute" }}<br/><br/>
		{% if my_teachers %}
			<b>Our Teachers:</b>
				{% for teacher in my_teachers|limit_array:4 %}
					<br/><a href="/myprofile/{{ teacher.abstract_user.id }}/">{{ teacher.abstract_user }}</a><br/>
					{% if teacher.teaches %}
						<small>Teaches: {{ teacher.teaches }}</small>
					{% endif %}
				{% endfor %}
			{% if my_teachers|length == 4 %}
				<small><a href="/myprofile/connections/{{ currentUser.abstract_user.id }}/">See all</a></small>
			{% endif %}
			<br/><br/>
		{% endif %}
		<b>Open On: </b><br/>{{ currentUser.open_on|default:"Ahm, is it closed all week long?" }}<br/><br/>
		<b>Open From: </b><br/>{{ currentUser.open_from|default:"Is it open 24hrs aday?" }}<br/><br/>
		<b>Open To: </b><br/>{{ currentUser.open_to|default:"Never closes?"}}<br/><br/>
		<b>Address: </b><br/>{{ currentUser.address|default:"Even if you're located on Mars, you can tell us, we really don't mind" }}<br/><br/>
		<b>Contact Info: </b><br/>{{ currentUser.contact_info|default:"Are you reachable? Phone?" }}<br/><br/>
	{% else %}
	
		<b>Date of Birth: </b><br/>{{ currentUser.dob|default:"Not entered yet" }}<br/><br/>
		<b>Gender: </b><br/>{{ currentUser.gender|default:"Are you unsure?" }}<br/><br/>
		<b>Experience: </b><br/>{{ currentUser.experience|default:"Come on, BRAG!" }}<br/><br/>
		<b>Favorite Genre/s: </b><br/>{{ currentUser.favourite_genre|default:"Hmm, you must like something, right?" }}<br/><br/>
		<b>Instrument/s Played: </b><br/>{{ currentUser.instrument_played|default:"Ahm, it is kind of in the definition of a musician to play something. Unless you're a vocalist...'" }}<br/><br/>
		<b>Jamming Style: </b><br/>{{ currentUser.jamming_style|default:"Tell us..." }}<br/><br/>
		
		{% if currentUser.category == "teacher" %}
			<b>Teach: </b><br/>{{ currentUser.teaches|default:"Advertise for yourself..." }}<br/><br/>
		{% endif %}
			
	{% endif %}
<small style="text-align:center">
	<a href="/editInfo/">Edit My Info</a> - 
	{% if photo %}	
		<a href="/myprofile/uploadImage/">Change Photo</a> - 
	{% else %}
		<a href="/myprofile/uploadImage/">Upload a Photo</a> - 
	{% endif %}
	<a href="/myprofile/changePassword/">Change Password</a>
</small>
	
{% else %}
	{% if currentUser.category == "institute" %}
		{% if currentUser.about %}
			<b>About: </b><br/>{{ currentUser.about }}<br/><br/>
		{% endif %}
		{% if my_teachers %}
			<b>Our Teachers:</b>
				{% for teacher in my_teachers|limit_array:4 %}
					<br/><a href="/myprofile/{{ teacher.abstract_user.id }}/">{{ teacher.abstract_user }}</a><br/>
					{% if teacher.teaches %}
						<small>Teaches: {{ teacher.teaches }}</small>
					{% endif %}
				{% endfor %}
			{% if my_teachers|length == 4 %}
				<small><a href="/myprofile/connections/{{ currentUser.abstract_user.id }}/">See all</a></small>
			{% endif %}
			<br/><br/>
		{% endif %}
		{% if currentUser.open_on %} 
			<b>Open On: </b><br/>{{ currentUser.open_on }}<br/> <br/>
		{% endif %}
		{% if currentUser.open_from %} 
			<b>Open From: </b><br/>{{ currentUser.open_from }}<br/> <br/>
		{% endif %}
		{% if currentUser.open_to %} 
			<b>Open To: </b><br/>{{ currentUser.open_to }}<br/> <br/>
		{% endif %}
		{% if currentUser.address %} 
			<b>Address: </b><br/>{{ currentUser.address }}<br/> <br/>
		{% endif %}
		
	{% else %}
	
		{% if currentUser.dob %} 
			<b>Date of Birth: </b><br/>{{ currentUser.dob }}<br/> <br/>
		{% endif %}
		{% if currentUser.gender %} 
			<b>Gender: </b><br/>{{ currentUser.gender }}<br/> <br/>
		{% endif %}
		{% if currentUser.experience %} 
			<b>Experience: </b><br/>{{ currentUser.experience }}<br/> <br/>
		{% endif %}
		{% if currentUser.favourite_genre %} 
			<b>Favourite Genre/s: </b><br/>{{ currentUser.favourite_genre }}<br/> <br/>
		{% endif %}
		{% if currentUser.instrument_played %} 
			<b>Instrument/s Played: </b><br/>{{ currentUser.instrument_played }}<br/> <br/>
		{% endif %}
		{% if currentUser.jamming_style %} 
			<b>Jamming Style: </b><br/>{{ currentUser.jamming_style }}<br/> <br/>
		{% endif %}
		
		{% if currentUser.category == "teacher" %}
			{% if currentUser.teaches %}
				<b>Teach: </b><br/>{{ currentUser.teaches }}<br/><br/>
			{% endif %}
		{% endif %}
			
	{% endif %}
	
{% endif %}
{% endblock %}